<template>
  <div>
    <!--兼职大包编辑审核-->
    <el-form
      :inline="true"
      label-position="right"
      size="small"
      class="filter-form-inline"
    >
      <el-row
        :gutter="40"
        style="margin-left: 0px;margin-right:0px;"
      >
        <el-col :span="8">
          <el-form-item
            label="流程编号："
            style="width: 100%;"
          >
            {{ detailData.processNo }}
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item
            label="创建时间："
            style="width: 100%;"
          >
            {{ dateFormat('yyyy-mm-dd HH:MM',detailData.startTime) }}
          </el-form-item>
        </el-col>
        <el-col :span="8">
          <el-form-item
            label="创建人："
            style="width: 100%;"
          >
            {{ detailData.initiator }}
          </el-form-item>
        </el-col>
        <el-col
          :span="24"
          style="padding-left: 0;padding-right: 0"
        >
          <item-title title="基本信息" />
        </el-col>
        <el-col
          :lg="8"
          :xs="4"
        >
          <el-form-item label="兼职人员姓名：">
            <span>{{ detailData.data?.agent.userName }}</span>
          </el-form-item>
        </el-col>
        <el-col
          :lg="8"
          :xs="4"
        >
          <el-form-item
            label="性别："
            class="item_col"
          >
            <span v-if="detailData.data?.agent.sex === '1'">男</span>
            <span v-if="detailData.data?.agent.sex === '2'">女</span>
          </el-form-item>
        </el-col>
        <el-col
          :lg="8"
          :xs="4"
        >
          <el-form-item label="联系电话：">
            <span>{{ detailData.data?.agent.tel }}</span>
          </el-form-item>
        </el-col>
        <el-col
          :lg="8"
          :xs="4"
        >
          <el-form-item label="身份证：">
            <span>{{ detailData.data?.agent.cardNumber }}</span>
          </el-form-item>
        </el-col>
        <el-col
          :lg="24"
          :xs="4"
        >
          <el-form-item label="身份证附件：">
            <div
              v-for="(item,index) in detailData.data?.agent.cardFiles"
              :key="index"
              class="file-item"
            >
              <image-upload-view
                :data="item"
                :disabled="disabled"
              />
            </div>
          </el-form-item>
        </el-col>

        <!--        <el-col :lg="24" :xs="4" style="padding-left: 0;padding-right: 0">-->
        <!--          <item-title title="合同信息"/>-->
        <!--        </el-col>-->
        <!--        <el-col :span="8">-->
        <!--          <el-form-item label="合同编号：" style="width: 100%;">-->
        <!--            {{detailData.data.contract.contractNumber}}-->
        <!--          </el-form-item>-->
        <!--        </el-col>-->
        <!--        <el-col :span="8">-->
        <!--          <el-form-item label="合同名称：" style="width: 100%;">-->
        <!--            {{detailData.data.contract.contractName}}-->
        <!--          </el-form-item>-->
        <!--        </el-col>-->
        <!--        <el-col :span="8">-->
        <!--          <el-form-item label="合同类型：" style="width: 100%;">-->
        <!--            {{ getLabel('contract_type', detailData.data.contract.contractObjectType) }}-->
        <!--          </el-form-item>-->
        <!--        </el-col>-->
        <!--        <el-col :span="8">-->
        <!--          <el-form-item label="合同开始日期：" style="width: 100%;">-->
        <!--            {{ dateFormat("yyyy-mm-dd HH:MM:SS", detailData.data.contract.contractBeginTime) }}-->
        <!--          </el-form-item>-->
        <!--        </el-col>-->
        <!--        <el-col :span="8">-->
        <!--          <el-form-item label="合同结束日期：" style="width: 100%;">-->
        <!--            {{ dateFormat("yyyy-mm-dd HH:MM:SS", detailData.data.contract.contractEndTime) }}-->
        <!--          </el-form-item>-->
        <!--        </el-col>-->
        <!--        <el-col :span="8">-->
        <!--          <el-form-item label="合同负责人：" style="width: 100%;">-->
        <!--            {{detailData.data.contract.contractHeadName}}-->
        <!--          </el-form-item>-->
        <!--        </el-col>-->
        <!--        <el-col :span="8">-->
        <!--          <el-form-item label="归属部门：" style="width: 100%;">-->
        <!--            {{detailData.data.contract.contractDepartmentName}}-->
        <!--          </el-form-item>-->
        <!--        </el-col>-->
        <!--        <el-col :span="8">-->
        <!--          <el-form-item label="合同金额：" style="width: 100%;">-->
        <!--            {{detailData.data.contract.contractAmount}}-->
        <!--          </el-form-item>-->
        <!--        </el-col>-->
        <!--        <el-col :span="24">-->
        <!--          <el-form-item label="合同附件：" style="width: 100%;">-->
        <!--            <div style="display: flex;justify-content: flex-start;align-items: flex-start;flex-wrap: wrap;">-->
        <!--              <div v-for="(item,index) in detailData.data.contract.contractFile" :key="index"-->
        <!--                   style="margin-right: 20px">-->
        <!--                <el-button type="text" @click="handlDownload(item)">-->
        <!--                  {{item.name}}-->
        <!--                </el-button>-->
        <!--              </div>-->
        <!--            </div>-->
        <!--          </el-form-item>-->
        <!--        </el-col>-->

      </el-row>
    </el-form>
  </div>
</template>

<script>
import {reactive, toRefs, watch} from 'vue'

export default {
  name: 'PartTimeBigBagEdit',
  props: {
    detailData: {
      type: Object,
      default() {
        return {
          data: {
            agent: {},
          },
        }
      },
    },
  },
  setup(props) {
    var data = reactive({
      detailData: {},
    })
    watch(
      () => props.detailData,
      (newval, oldval) => {
        if (newval) {
          data.detailData = newval
          console.log(newval, '------------')
        }
      },
      { immediate: true, deep: true }
    )
    return {
      ...toRefs(data),
    }
  },
}
</script>

<style lang="scss" scoped>
</style>
